/*
 * @Date: 2021-08-18 09:43:41
 * @information:
 */
import UserModel from '../model/UserModel'


export default class UserDao {
  async findById (data) {
    const { id } = data
    return await UserModel.findOne({
      attributes: { exclude: ['isdelete'] }, // 返回值排除字段
      where: {
        isdelete: 0,
        id,
      },
    })
  }

  async add (data) {
    return await UserModel.create(data)
  }




}
